package main

import "fmt"

func avgOfArr(arr [5]int) {

	var sum int
	for _, v := range arr {
		sum += v
	}
	fmt.Println("数组的平均值为：", sum / len(arr))

}

func main() {

	var arr [5]int = [5]int {1, 2, 3, 4, 5}
	avgOfArr(arr)

}